-- GENERATED SPELL FOR [Chromatic Dragonspawn] --


function spell0_10447(pUnit, Event) --@Cleave,n/a--
pUnit:FullCastSpellOnTarget(15284,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_10447', 602, 1)
end

function spell1_10447(pUnit, Event) --@Strike,n/a--
pUnit:FullCastSpellOnTarget(15580,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_10447', 603, 1)
end

function Sorts_10447(pUnit, Event)
local choix_sorts_10447 = math.random(0, 1)
if choix_sorts_10447 == 0 then
pUnit:RegisterEvent('spell0_10447', 1, 1)
end
if choix_sorts_10447 == 1 then
pUnit:RegisterEvent('spell1_10447', 1, 1)
end
end

function mob10447_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_10447', math.random(1500, 3000), 1)
end

function mob10447_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob10447_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob10447_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(10447, 1, 'mob10447_Action')
RegisterUnitEvent(10447, 2, 'mob10447_Leave')
RegisterUnitEvent(10447, 3, 'mob10447_Kill')
RegisterUnitEvent(10447, 4, 'mob10447_Die')
